<%@ page contentType="text/html; charset=utf-8"%>
<%@ taglib prefix="s" uri="/struts-tags" %>
<%@ taglib uri="/WEB-INF/FCKeditor.tld" prefix="FCK"%>
<html>
<head>
<title>创建文章</title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<script type="text/javascript" src="fckeditor/fckeditor.js"></script>
<script type="text/javascript">
	function FCKeditor_OnComplete(editorInstance) {
		window.status = editorInstance.Description;
	}
</script>
</head>
<body>
<table style="width: 1024px;" align="center">
	<tr>
		<td><s:include value="/common/header.jsp" />
		<div style="height: 500px;">
		<s:actionmessage /> 
		<s:form action="/article" theme="simple" enctype="multipart/form-data" method="post">   
			<s:textfield key="title" label="标题" />
			<s:hidden key="categoryId" value="%{id}"/>
			<s:if test="subCategorys!=null && subCategorys.size>0">
				<s:select list="subCategorys" key="subCategoryId" 
					label="分类" listKey="id" listValue="categoryName"/>
			</s:if>
			<table>
				<tr><td>
					<FCK:editor instanceName="content" height="400" width="800">
						<jsp:attribute name="value">
							<s:property value="%{#request.content}" escape="false"/>
						</jsp:attribute>
					</FCK:editor>
				</td></tr>
			</table>
			<s:fielderror />
			文件上传<s:file key="uploadFiles"/><br>
			文件上传<s:file key="uploadFiles"/><br>
			文件上传<s:file key="uploadFiles"/><br>
			<s:hidden key="fileSaveType" value="toDb"/>
			<s:submit/>
		</s:form></div>
		<s:include value="/common/footer.jsp" /></td>
	</tr>
</table>
</body>
</html>